package demo07.Synchronized;
/*
    模拟卖票案例
    创建3个线程,同时开启,对共享的票进行出售
 */
public class Demo01Ticket {
    public static void main(String[] args) {
        RunnableImpl runnable=new RunnableImpl();

        Thread t0=new Thread(runnable);
        Thread t1=new Thread(runnable);
        Thread t2=new Thread(runnable);

        t0.start();
        t1.start();
        t2.start();
    }
}
